package com.f37.f37git001.controller;

import com.f37.f37git001.bean.Commodity;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class CommodityController {
    @GetMapping("/commodity")
    public Commodity commodity(){
        Commodity commodity = new Commodity();
        commodity.setId(1);
        commodity.setName("手机");
        commodity.setPrice("4000");
        commodity.setStock(100);
        return commodity;
    }
}
